unit SmallStruct.Core.TSSSystemObject;

interface

uses
  Classes,
  atScript,
  SmallStruct.Core,
  SmallStruct.Core.TSSRuntimeObject,
  SmallStruct.Configuration;

type
  TSSSystemObject = class(TSSRuntimeObject, ISSSystemObject)
  private
    _ClassTable: ISSClassTable;
    _GlobalObjectTable, _ResourceTable: ISSObjectContainer;
    _ConfigurationTable: ISSConfigurationTable;
  protected
    function GetClassTable: ISSObject;
    function GetConfigurationTable: ISSObject;
    function GetGlobalObjectTable: ISSObject;
    function GetResourceTable: ISSObject;
  public
    procedure InitObject; override;
  public
    constructor Create(AOwner: TComponent); override;
    destructor Destroy; override;
  end;

  TSSSystemObjectScriptObject = class(TatScripterLibrary)

  end;

implementation

uses SmallStruct.Core.TSSClassTable,
  SmallStruct.Core.TSSObjectContainer,
  SmallStruct.Configuration.TSSConfigurationTable;

{ TSSSystemObject }

constructor TSSSystemObject.Create(AOwner: TComponent);
begin
  inherited;

  _ClassTable := TSSClassTable.Create(Self);
  _GlobalObjectTable := TSSObjectContainer.Create(Self);
  _ResourceTable := TSSObjectContainer.Create(Self);
end;

destructor TSSSystemObject.Destroy;
begin
  _ClassTable.ReleaseObjectInstance;
  inherited;
end;

function TSSSystemObject.GetClassTable: ISSObject;
begin
  Result := _ClassTable;
end;

function TSSSystemObject.GetConfigurationTable: ISSObject;
begin
  Result := _ConfigurationTable;
end;

function TSSSystemObject.GetGlobalObjectTable: ISSObject;
begin
  Result := _GlobalObjectTable;
end;

function TSSSystemObject.GetResourceTable: ISSObject;
begin
  Result := _ResourceTable;
end;

procedure TSSSystemObject.InitObject;
begin
  _ConfigurationTable := TSSConfigurationTable.Create(Self);
end;

end.
